/*
    ChibiOS-NRF-Driver - Copyright (C) 2012
            Joel Bodenmann aka Tectu <joel@unormal.org>
            Paul Honig aka Ranzbak <paul@swarmtv.nl>    

    This file is part of ChibiOS-NRF-Driver.

    ChibiOS-NRF-Driver is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 3 of the License, or
    (at your option) any later version.

    ChibiOS-NRF-Driver is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef NRF_SPI_H
#define NRF_SPI_H

/*
* Initialize the SPI interface
*/
void SPIInit(void);

/*
* SPI bus exchange routine
*/
int SPIExchangeData(SPIDriver *spip, uint8_t *tx, uint8_t *rx, size_t size);

/*
* SPI bus exchange routine
*/
int SPIExchangeDataI(SPIDriver *spip, uint8_t *tx, uint8_t *rx, size_t size);

/*
* SPI bus send routine
*/
int SPISendData(SPIDriver *spip, uint8_t *tx, size_t size);

/*
* SPI bus receive routine
*/
int SPIReceiveData(SPIDriver *spip, uint8_t *rx, size_t size);

#endif /* NRF_SPI_H */

